package org.example.consume2.Controller;

import org.springframework.context.annotation.Bean;
import org.springframework.stereotype.Component;

import java.util.function.Consumer;


@Component
public class ConsumerComponent {
    @Bean("myChannel")
    public Consumer<String> myChanel() {
        return message -> System.out.println("新版本消息:" + message);
    }
}